import 'package:app/interceptor.dart';
import 'package:app/util/ThemeConfigUtil.dart';
import 'package:app/util/WebSocketInheritedWidget.dart';
import 'package:app/util/WebSocketManager.dart';
import 'package:bruno/bruno.dart';
import 'package:flutter/material.dart';
import 'package:app/route.dart';
void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    BrnInitializer.register(allThemeConfig: ThemeConfigUtil.defaultAllConfig);
    return WebSocketInheritedWidget(
      socket: WebsocketManager(),
      child: MaterialApp(
        title: '秦烟机物流',
        theme: ThemeData(
          colorScheme: ColorScheme.fromSeed(seedColor: Colors.black),
          useMaterial3: false,
        ),
        home: const Interceptor(),
        routes: routes,
      ),
    );
  }
}
